import request from '@/utils/request'

// 查询安全培训列表
export function listOpmFoodSafeTrain(query) {
  return request({
    url: '/food/opmFoodSafeTrain/list',
    method: 'get',
    params: query
  })
}

// 查询安全培训详细
export function getOpmFoodSafeTrain(id) {
  return request({
    url: '/food/opmFoodSafeTrain/' + id,
    method: 'get'
  })
}

// 新增安全培训
export function addOpmFoodSafeTrain(data) {
  return request({
    url: '/food/opmFoodSafeTrain',
    method: 'post',
    data: data
  })
}

// 修改安全培训
export function updateOpmFoodSafeTrain(data) {
  return request({
    url: '/food/opmFoodSafeTrain',
    method: 'put',
    data: data
  })
}

// 删除安全培训
export function delOpmFoodSafeTrain(id) {
  return request({
    url: '/food/opmFoodSafeTrain/' + id,
    method: 'delete'
  })
}
